package com.ruoyi.project.seeDoctor.service.impl;

import com.ruoyi.project.seeDoctor.domain.MedPati;
import com.ruoyi.project.seeDoctor.domain.SysDepts;
import com.ruoyi.project.seeDoctor.domain.SysRegistrationCost;
import com.ruoyi.project.seeDoctor.mapper.IRegisterMapper;
import com.ruoyi.project.seeDoctor.service.IRegisterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RegisterServiceImpl implements IRegisterService {
    @Autowired
    private IRegisterMapper iRegisterMapper;
    //根据code查询患者信息
    @Override
    public List<MedPati> selMedPatiByCodeService(String code) {
        return iRegisterMapper.selIRegisterByCode(code);
    }

    //查询挂号收费信息
    @Override
    public List<SysRegistrationCost> selSysRegistrationCostService() {
        return iRegisterMapper.selSysRegistrationCostInfo();
    }
    //查询科室信息
    @Override
    public List<SysDepts> selSysDeptsService(String depts_name) {
        return iRegisterMapper.selSysDeptsMapperInfo(depts_name);
    }

    //添加患者信息
    @Override
    public int insMedPariService(MedPati medPati) {
        int i = iRegisterMapper.insRegisterMapperInfo(medPati);
        return i;
    }

    //查询患者信息

    @Override
    public List<MedPati> selMedPatiListService(MedPati medPati) {
        return iRegisterMapper.selIRegisterList(medPati);
    }
}
